import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 26727
 * Date: 2025-07-16
 * Time: 22:55
 */
public class Test57 {
    static List<List<Integer>> ret;
    static List<Integer> path;
    static public List<List<Integer>> subsets(int[] num) {
        ret = new ArrayList<>();
        path = new ArrayList<>();
        dfs(num,0);
        return ret;
    }

//    static void dfs(int[] num,int pos) {
//        if(pos == num.length) {
//            ret.add(new ArrayList<>(path));
//            return;
//        }
//        //选
//        path.add(num[pos]);
//        dfs(num,pos+1);
//        //不选
//        path.remove(path.size()-1);
//        dfs(num,pos+1);
//    }

    static void dfs(int[] num,int pos) {
//        空集 每个元素选或者不选 每一层叶子节点
        ret.add(new ArrayList<>(path));

        for(int i = pos; i < num.length; i++) {
            path.add(num[i]);
            dfs(num,i+1);
            path.remove(path.size()-1);
        }
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] num = new int[n];
        for(int i = 0; i < n; i++) {
            num[i] = sc.nextInt();
        }
        List<List<Integer>> ret = subsets(num);
        System.out.println(ret);
    }
}
